The present application claims priority from Japanese Application No. P2000-128127 filed Apr. 27, 2000, the disclosure of which is hereby incorporated by reference herein.
The present invention relates to electronic equipment provided with a physical layer circuit constituting a physical layer which conforms to the IEEE 1394 standard, and a method for controlling the state of the physical layer circuit.
More specifically, the present invention relates to electronic equipment in which the physical layer circuit is operated in such a manner that, when receiving a first signal from a child node, the physical layer circuit changes its state from a first state into a second state and sends a first signal to a parent node, and when receiving a third signal for canceling the first signal from the child node before receiving the second signal corresponding to the first signal from the parent node, the physical layer circuit sends the third signal to the parent node after receiving the second signal from the parent node, and furthermore, the physical layer circuit returns its state from the second state to the first state after receiving the third signal from the parent node, thereby avoiding the occurrence of trouble which may be caused if the physical layer circuit receives the second signal from the parent node in the first state.
The present invention also relates to electronic equipment in which the physical layer circuit is operated in such a manner that, when receiving a first signal from a child node, the physical layer circuit changes its state from a first state into a second state and sends the first signal to a parent node, and when receiving a third signal for canceling the first signal from the child node after receiving the second signal corresponding to the first signal from the parent node and shifting its state from the second state to the third state, the physical layer circuit sends the third signal to the parent node, and furthermore, the physical layer circuit returns its state from the third state to the first state after receiving the third signal from the parent node, thereby avoiding the occurrence of trouble which may be caused if the physical layer circuit receives the second signal from the parent node in the first state.
As the standard defining the interface for supporting high-speed data transmission and real-time transmission as the interface for multimedia data transmission, the IEEE 1394 high-performance serial bus standard (the IEEE 1394 standard) is known. The IEEE 1394 standard defines data transmission at rates of 100 Mbps (98.304 Mbps), 200 Mbps (196.608 Mbps), and 400 Mbps (393.216 Mbps), and defines a 1394 port with higher transmission rate to have compatibility with its lower transmission rate. This standard allows data transmissions at rates of 100 Mbps, 200 Mbps, and 400 Mbps in one and the same network.
In addition, the IEEE 1394 standard employs a transmission format in the Data/Strobe link (DS-Link) coding method. In the transmission format in the Data/Stroke link coding method, as shown in FIG. 1, transmission data is converted into two signals including data and strobe for compensating the signal thereof, and the exclusive OR of these two signals is obtained, thereby generating clocks. The IEEE 1394 standard also defines a cable 200 having a structure such as shown in the cross-sectional view of FIG. 2, including: first shielding layers 201; two pairs of twisted pair lines (i.e., signal lines) 202, each shielded by a first shielding layer 201; power supply lines 203; and a second shielding layer 204 which entirely covers the cable constituted by tying the first shielding layers 201, the twisted pair lines 202, and the power supply lines 203 together.
The IEEE 1394 standard performs arbitration for obtaining a bus prior to data transmission, and, as a control signal for arbitration, defines an arbitration signal. In addition, the IEEE 1394 standard automatically reconfigures the entire bus topology by resetting the bus at the time when a node is added to or deleted from the bus. The arbitration signal is also defined as a control signal required for the topology reconfiguration.
The logical values of the arbitration signal in the physical layer are three values of xe2x80x9c0xe2x80x9d, xe2x80x9c1xe2x80x9d, and xe2x80x9cZxe2x80x9d. These values are produced in accordance with the rules shown in Tables 1 and 2 below, and are decoded in accordance with the rule shown in Table 3 below.
In addition, the physical layer encodes the line state by use of two transmission arbitration signals Arb_A_Tx and Arb_B_Tx in accordance with the rules shown in Table 4 below, and decodes the line state by use of receive arbitration signals Arb_A and Arb_B in accordance with the rules shown in Table 5 below.
By use of the arbitration signals described above, the topology is automatically configured through the bus initialization phase, tree identification phase, and self-identification phase in this order.
At the bus initialization phase, the bus reset signal changes all the nodes into particular states, to entirely clear the topology information. As a result of the bus initialization, each node has information only about whether the node itself is a branch (i.e., whether it is directly connected to a plurality of nodes adjacent thereto), whether the node is a leaf (i.e., whether it is connected to only a single node adjacent thereto), and whether the node is independent (i.e., whether it is connected to no nodes adjacent thereto). FIG. 3A is a diagram showing a network constituted by leaf nodes and branch nodes.
At the tree identification phase, the entire network topology is converted into one tree in which one node is designated as a root. All the physical connections connected to the root indicate the direction of the root node. Each port for connection in each node is assigned a label to indicate the direction, and is referred to as a xe2x80x9cparentxe2x80x9d port (in the case where the port is connected to a node closer to the root), or a xe2x80x9cchildxe2x80x9d port (in the case where the port is connected to a node more remote from the root). A port which is not connected to any node is assigned with a label xe2x80x9coffxe2x80x9d, and does not participate in the arbitration process conducted afterwards. FIG. 3B shows the network constituted at the completion of the tree identification process.
At the self-identification phase, each node is provided with an opportunity to select its own specific physical_ID to identify itself with respect to an arbitrary control element associated with the bus. This process is also necessary to control electric power of low level, and to produce a topology map of the system required for determining the rate of each data path.
The self-identification process employs a theoretic decision selection process. Specifically, a root node leaves the media control to the node associated with the connection port having the smallest number, and waits until the node sends an xe2x80x9cident_donexe2x80x9d signal for notifying that the node itself and all the child nodes thereof have completed self-identification. After that, the root node leaves the control to the node associated with the connection port having the next larger number, and waits until the processing of the node has been completed. When the nodes associated with all the ports of the root have completed their processings, the root itself conducts self-identification. The child nodes conduct the same process as above, respectively. The completion of the self-identification process is acknowledged when the bus goes into an idle state over a subaction gap period.
Each node can send its self-identification information by sending one to four very short packets (Self-ID Packets) involving physical_ID or other control information to a cable. The physical_ID is a value obtained by simply counting the number of times the node receives self-identification information from the other nodes before it sends its self-identification packet. For example, the node which sends its self-identification packet first selects a 0 as a physical_ID, and the node which sends its self-identification packet second selects a 1 as a physical_ID. The same process is repeated to determine the physical_ID of the nodes which send their self-identification packets third and thereafter. FIG. 3C shows the network obtained at the completion of the self-identification process. As seen in FIG. 3C, each xe2x80x9cchildxe2x80x9d port is assigned with a xe2x80x9cch-ixe2x80x9d label by which the node connected to the port can be identified.
In the IEEE 1394-1995 and 1394.a definition, the behavior of the physical layer at the time it receives a signal for canceling a request at an arbitration phase is defined as follows: xe2x80x9cwhen a child node which is making a request cancels the request, the physical layer (PHY) at the permission side observes its TX_GRANT signal to be returned thereto as a RX_REQUEST_CANCEL signal [Z0], and returns its state to an idle statexe2x80x9d (The transition of A1:A0 and transition of A2:A0 in FIG. 4). FIG. 4 is a transition diagram at an arbitration phase, showing an A0 (Idle) state, an A1 (Request) state, an A2 (Grant) state, an RX (Receive) state, a TX (Transmit) state, and a PH (PHY Response) state, respectively.
However, as shown in Table 5 above, since the RX_GRANT signal [00] and the RX_SUSPEND signal [00] use an identical code, a problem arises in the above operation depending on the way that the physical layer is mounted. That is, although the physical layer is in the state of receiving the RX_GRANT signal from the parent node, when it observes the RX_REQUEST_CANCEL signal from the child node and changes its state into the idle state, the physical layer misunderstands the RX_GRANT signal from the parent node as the RX_SUSPEND signal. As a result, a situation may arise that the port connected to the parent node changes its state into a suspended state. FIG. 5 is a transition diagram at a port connection, showing a P0 state (Disconnected), a P1 state (Resuming), a P2 state (Active), a P3 state (Suspended Initiator), a P4 state (Suspended Target), a P5 state (Suspended), and a P6 state (Disabled), respectively.
Hereinafter, description will be made of the behavior of a node B at the time when a node A makes a request for the right to use the bus for transmission, and after that, the node A cancels the request, taking as an example the case where 5 nodes are connected to each other, with a node C as a root node as shown in FIG. 6A. In FIGS. 6A to 9C, arrows show transmission and receipt of data, and the terms IDLE, REQ, GRANT, RECEIVE, and TRANS in the respective nodes show the states of the physical layers of the respective nodes. The diagonally shaded arrows show a request signal and a grant signal (same signals are allocated in the IEEE 1394-1995 and 1394.a standard), the grid-patterned arrows show a data prefix signal, and the filled-in arrows show a data payload.
First, a flow from (1.1) to (1.8) will be described as a normal flow of data transmission from a point where the node A makes a request to obtain the right to use the bus for transmission until a point where the node A transmits data.
In order to obtain the right to use the bus for transmission, the node A changes its state into a request state where the node A transmits a request signal (FIG. 6A).
Upon receiving the request signal from the node A, the node B changes its state into a request state where the node B repeats the request signal to the node C which is a parent node (FIG. 6B).
Upon receiving the request signal from the node B, the node C confirms that there is no request signal other than that from the node B, and changes its state into a grant state where the node C transmits a grant signal to the node B. At the same time, the node C transmits a data prefix to the other node, that is, the node E. Upon receiving the data prefix signal, the node E changes its state into a receive state (FIG. 6C).
(1.4) Upon receiving the grant signal, the node B changes its state into a grant state where the node B repeats the grant signal to the node A. At the same time, the node B transmits a data prefix signal to the other node, that is, the node D. Upon receiving the data prefix signal, the node D changes its state into a receive state (FIG. 6D).
(1.5) Upon receiving the grant signal, the node A has obtained the right to use the bus for transmission. The node A therefore changes its state into a transmission state where the node A switches the request signal to the data prefix signal (FIG. 7A).
(1.6) Upon receiving the data prefix signal from the node A, the node B changes its state into a receive state where the node B repeats the data prefix signal to the nodes C, D. Upon receiving the data prefix signal from the node B, the node C changes its state into a receive state where the node C repeats the data prefix signal to the node E (FIG. 7B).
(1.7) After the node A keeps the data prefix signal for a period of time defined by the IEEE 1394 standard, the node A starts to transmit the data payload to the node B (FIG. 7C).
(1.8) Upon receiving the data payload from the node A, the node B repeats the data payload to the nodes C and D. Furthermore, upon receiving the data payload from the node B, the node C repeats the data payload to the node E (FIG. 7D).
Next, a flow from (2.1) to (2.3) will be described, where the node B receives an idle signal from the node A after the step (1.2) in the above-described flow has been completed and during when the node B is transmitting the request signal to the node C.
(2.1) In the state where the node B repeats the request signal to the node C and waits to receive a grant signal from the node C, if the node A cancels the request for any reason, the node B receives an idle signal from the node A (FIG. 8A).
(2.2) Upon receiving the idle signal from the node A, the node B returns its state into an idle state (FIG. 8B).
(2.3) If the node B, after returning its state into the idle state, receives a grant signal [Z0] already transmitted from the node C before the request signal [Z0] to the node C has been cancelled, the node B misunderstands that it has received a suspend signal [00] (the [00]signal received in the idle state is understood as a suspend signal), although it actually is the grant signal [Z0]. In this case, the node B erroneously changes its state into a suspend state, resulting in occurrence of troubles (FIG. 8C).
Next, a flow from (3.1) to (3.3) will be described, where the node B receives a request cancel signal from the node A after the step (1.4) has been completed in the above-described flow and during when the node B is receiving the grant signal from the node C.
(3.1) In the state where the node B repeats the request signal to the node C, and receives the grant signal from the node C, if the node A cancels a request for any reason, the node B receives a request cancel signal from the node A (FIG. 9A).
(3.2) Upon receiving the request cancel signal from the node A, the node B returns its state into an idle state (FIG. 9B).
(3.3) The node B, after returning to the idle state, is in the state where it is transmitting a request signal [Z0] to the node C and also is receiving a grant signal [Z0] from the node C. In this state, the node B misunderstands that it has received a suspend signal [00] (the [00]signal received in the idle state is understood as a suspend signal). As a result, the node B erroneously changes its state into a suspend state, resulting in occurrence of troubles (FIG. 9C).
An objective of the present invention is to provide electronic equipment capable of preventing the occurrence of problems such as described above, and a method for controlling the state of the physical layer circuit of such electronic equipment.
In an aspect of the present invention, electronic equipment comprises a physical layer circuit having a first transmitter operable to communicate with a child node; a second transmitter operable to communicate with a parent node; and a controller operable to control the physical layer circuit such that, when the physical layer circuit receives a first signal from the child node, the physical layer circuit changes from a first state to a second state and transmits the first signal to the parent node, when the physical layer circuit receives a third signal for canceling the first signal from the child node before receiving a second signal corresponding to the first signal from the parent node, the physical layer circuit transmits the third signal to the parent node after receiving the second signal from the parent node, and when the physical layer circuit receives the third signal from the parent node, the physical layer circuit changes from the second state to the first state.
For example, the physical layer circuit may constitute a physical layer which conforms to the IEEE 1394 standard. In such event, the first state may be an idle state and the second state may be a request state. The first signal may be a request signal for obtaining a right to use a bus for transmission, the second signal may be a grant signal, and the third signal may be an idle signal.
In another aspect of the present invention, a method for controlling a state of a physical layer circuit includes receiving in the physical layer circuit a first signal from a child node; upon receipt of the first signal, controlling the physical layer circuit to change from a first state to a second state and to transmit the first signal to the parent node; receiving in the physical layer circuit a third signal for canceling the first signal from the child node before receiving a second signal corresponding to the first signal from the parent node; controlling the physical layer circuit to transmit the third signal to the parent node after receiving the second signal from the parent node; and controlling the physical layer circuit to change from the second state to the first state after receiving the third signal from the parent node.
In the present invention, the physical layer circuit is free from the situation in which it receives a second signal from the parent node while in the first state. This arrangement serves to prevent the occurrence of problems which may arise if the physical layer circuit receives the second signal from the parent node while in the first state. For example, when the physical layer circuit constitutes a physical layer which conforms to the IEEE 1394 standard, if the physical layer circuit receives an idle signal for canceling a request signal from a child node in a request state, the physical layer circuit changes to an idle state after it has received an idle signal from the parent node. There arises no situation in which the physical layer circuit receives a grant signal [00] from the parent node while in the idle state. This arrangement serves to prevent the occurrence of problems that may result if the physical layer circuit misunderstands that it has received a suspend signal and changes its state to a suspend state.
In still another aspect of the present invention, electronic equipment comprises a physical layer circuit having a first transmitter operable to communicate with a child node; a second transmitter operable to communicate with a parent node; and a controller operable to control the physical layer circuit such that, when the physical layer circuit receives a first signal from the child node, the physical layer circuit changes from a first state to a second state and transmits the first signal to the parent node; when the physical layer circuit receives a third signal for canceling the first signal from the child node after receiving a second signal corresponding to the first signal from the parent node and changing from the second state to a third state, the physical layer circuit transmits the third signal to the parent node; and after receiving the third signal from the parent node, the physical layer circuit changes from the third state to the first state.
For example, the physical layer circuit may constitute a physical layer which conforms to the IEEE 1394 standard. In such event, the first state may be an idle state, the second state may be a request state, and the third state may be a grant state. The first signal may be a request signal for obtaining a right to use a bus for transmission, the second signal may be a grant signal, and the third signal may be an idle signal.
In a further method for controlling a state of a physical layer circuit according to the present invention, the physical layer circuit receives a first signal from a child node. Upon receipt of the first signal, the physical layer circuit is controlled to change from a first state to a second state and to transmit the first signal to the parent node. When the physical layer circuit receives a third signal for canceling the first signal from the child node after receiving a second signal corresponding to the first signal from the parent node and changing from the second state to a third state, the physical layer circuit is controlled to transmit the third signal to the parent node. When the physical layer circuit receives the third signal from the parent node, the physical layer circuit is controlled to change from the third state to the first state.
In the present invention, the physical layer circuit is free from the problem that it receives a second signal from the parent node while in the first state. This arrangement serves to prevent the occurrence of problems which may result if the physical layer circuit receives the second signal from the parent node while in the first state. For example, when the physical layer circuit constitutes a physical layer which conforms to the IEEE 1394 standard, if the physical layer circuit receives an idle signal for canceling a request signal from a child node while in a grant state, the physical layer circuit changes to an idle state after it has received an idle signal from the parent node. There arises no situation in which the physical layer circuit receives a grant signal [00] from the parent node while in the idle state. This arrangement serves to prevent the problems that may result if the physical layer circuit misunderstands that it has received a suspend signal, although it actually has received a grant signal, and changes its state to a suspend state.